/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Topka;

import java.awt.event.MouseEvent;
import java.awt.event.MouseMotionListener;

/**
 *
 * @author Asko
 */
public class MouseMove implements MouseMotionListener {
     
    private double x ;
    private double y ;
    @Override
    public void mouseDragged(MouseEvent e) {
        System.out.println("Mouse dragged. Don't know what it means>");
    }

    @Override
    public void mouseMoved(MouseEvent e) {
        setX(e.getX());
        setY(e.getY());
        System.out.println("Mouse moved. Get coordinates:  X :" + e.getX()+
                " Y: " + e.getY());
    }

    public void setX(double x) {
        this.x = x;
    }

    public void setY(double y) {
        this.y = y;
    }
    
    public double getX() {
        System.out.println("Get x :" + x);
        return x;
    }

    public double getY() {
        System.out.println("Get y :" + y);
        return y;
    }
    
    public void changed(){
      
    }
    
    
    
}
